<template>
	<u-overlay :show="show" @click="onIsShowType()" opacity="0.9">
		<view class="warp">
			<view class="rect" @tap.stop>
				<video :src="src" :poster="poster" class="my-video"
				:style="{'height': height ? height + 'px' : '350px'}"></video>
			</view>
		</view>
	</u-overlay>
</template>

<script>
	export default {
		props: {
			show: Boolean,
			src: String,
			poster: String,
			height: Number
		},
		methods: {
			onIsShowType(){
				this.$emit('onShowType')
			}
		}
	}
</script>

<style lang="scss" scoped>
	.warp {
		display: flex;
		align-items: center;
		justify-content: center;
		height: 100%;
		.rect {
			width: 100%;
			background-color: #000000;
			.my-video{
				width: 100%;
				height: 350px;
			}
		}
	}
</style>
